//
//  BinaryTreeViewController.swift
//  StringForSwift
//
//  Created by DeLong Yang on 2017/7/27.
//  Copyright © 2017年 YiXue. All rights reserved.
/*
    在这个 class
    we  test binary tree  sort  
 */

import UIKit

class BinaryTreeViewController: UIViewController {

    override func viewDidLoad() {
        super.viewDidLoad()

        // Do any additional setup after loading the view.
        let tree = BinaryTreeNode.createTreeWith(values: [5,4,3,2,5,1,6,8,9])
        let node = BinaryTreeNode.treeNodeAt(index: 2, inTree: tree)
        print(node)
        print(tree)
        
    }

    override func didReceiveMemoryWarning() {
        super.didReceiveMemoryWarning()
        // Dispose of any resources that can be recreated.
    }
    

    /*
    // MARK: - Navigation

    // In a storyboard-based application, you will often want to do a little preparation before navigation
    override func prepare(for segue: UIStoryboardSegue, sender: Any?) {
        // Get the new view controller using segue.destinationViewController.
        // Pass the selected object to the new view controller.
    }
    */

}
